package com.zhiche.lisa.tms.dao.model;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableLogic;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 装车单明细
 * </p>
 *
 * @author qichao
 * @since 2018-06-20
 */
@TableName("lisa_shipment_detail")
public class ShipmentDetail extends Model<ShipmentDetail> {

    private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	@JsonSerialize(using=ToStringSerializer.class)
	private Long id;
	/**
	 * 运输任务编号
	 */
	@TableField("ship_task_code")
	private String shipTaskCode;
    /**
     * 装车单ID
     */
	@TableField("shipment_id")
	private Long shipmentId;
    /**
     * 运输任务开始顺序（0开始，数字越大，顺序约靠后）
     */
	@TableField("ship_task_origin_order")
	private Integer shipTaskOriginOrder;
    /**
     * 运输任务结束顺序（0开始，数字越大，顺序约靠后）
     */
	@TableField("ship_task_dest_order")
	private Integer shipTaskDestOrder;
    /**
     * 创建时间
     */
	@TableField("gmt_create")
	private Date gmtCreate;

	/**
	 * 租户ID
	 */
	@TableField("tenant_id")
	private Long tenantId;

	@TableField("is_delete")
	@TableLogic
	private Integer isDelete;

	public Integer getIsDelete() {
		return isDelete;
	}

	public void setIsDelete(Integer isDelete) {
		this.isDelete = isDelete;
	}
	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getShipTaskCode() {
		return shipTaskCode;
	}

	public void setShipTaskCode(String shipTaskCode) {
		this.shipTaskCode = shipTaskCode;
	}

	public Long getShipmentId() {
		return shipmentId;
	}

	public void setShipmentId(Long shipmentId) {
		this.shipmentId = shipmentId;
	}

	public Integer getShipTaskOriginOrder() {
		return shipTaskOriginOrder;
	}

	public void setShipTaskOriginOrder(Integer shipTaskOriginOrder) {
		this.shipTaskOriginOrder = shipTaskOriginOrder;
	}

	public Integer getShipTaskDestOrder() {
		return shipTaskDestOrder;
	}

	public void setShipTaskDestOrder(Integer shipTaskDestOrder) {
		this.shipTaskDestOrder = shipTaskDestOrder;
	}

	public Date getGmtCreate() {
		return gmtCreate;
	}

	public void setGmtCreate(Date gmtCreate) {
		this.gmtCreate = gmtCreate;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "ShipmentDetail{" +
				"id=" + id +
				", shipTaskCode='" + shipTaskCode + '\'' +
				", shipmentId=" + shipmentId +
				", shipTaskOriginOrder=" + shipTaskOriginOrder +
				", shipTaskDestOrder=" + shipTaskDestOrder +
				", gmtCreate=" + gmtCreate +
				'}';
	}

	public Long getTenantId() {
		return tenantId;
	}

	public void setTenantId(Long tenantId) {
		this.tenantId = tenantId;
	}
}
